import Vue from 'vue'
import App from './App'

// 路由插件
// 导入路由
import {RouterMount} from 'uni-simple-router';

//使用ui库
import uView from "uview-ui";
Vue.use(uView);

import store from "./store/index.js";
Vue.prototype.$store = store

import api from './api/index.js'
Vue.prototype.$api = api;
Vue.config.productionTip = false

import config from './config/config.js'
Vue.prototype.$baseUrl = config.baseUrl;

import http from './http/index.js'
Vue.prototype.$http = http;

App.mpType = 'app'

const app = new Vue({
	store,
    ...App
})

//v1.3.5起 H5端 你应该去除原有的app.$mount();使用路由自带的渲染方式
// #ifdef H5
	import wxsdk from '@/common/wechat/sdk'
	Vue.prototype.$wxsdk = wxsdk;
	RouterMount(app,'#app');
// #endif

// #ifndef H5
	app.$mount(); //为了兼容小程序及app端必须这样写才有效果
// #endif

